package org.example.learn.javaagent.threadlocal_link_to_track;

// 测试 ThreadLocal 链路追踪
public class TestRun {

    public static void main(String[] args) {
        // 线程一
        new Thread(new Runnable() {
            @Override
            public void run() {
                new TestRun().A();
            }
        }).start();

        // 线程二
        new Thread(new Runnable() {
            @Override
            public void run() {
                new TestRun().A();
            }
        }).start();
    }

    public void A(){
        System.out.println("This is A!");
        B();
    }

    public void B(){
        System.out.println("This is B!");
        C();
    }

    public void C(){
        System.out.println("This is C!");
    }
}
